﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Text;
using System.Threading.Tasks;
 
namespace Solidi
{
	public class DependencyConstructorParameter
	{
		private ParameterInfo _parameter;
		private IDependencyKey _key;

		public DependencyConstructorParameter(ParameterInfo parameter)
		{
			_parameter = parameter;
		}

		public IDependencyKey Key
		{
			get
			{
				if (_key == null)
				{
					_key = new DependencyKey(_parameter.ParameterType);
				}

				return _key;
			}
		}

		public Type ParameterType
		{
			get
			{
				return _parameter.ParameterType;
			}
		}
	}
}
